class Anuncio < ActiveRecord::Base


	validates_presence_of :descricao, message: "- campo obrigatorio"
	validates_presence_of :titulo, message: "- campo obrigatorio"
	validates_presence_of :preco, message: "- campo obrigatorio"
	has_many :comentarios
	scope :most_recent, order("created_at DESC")
	

end
